package com.cyt.work.question.service;

import com.cyt.base.model.dto.ReturnResult;
import com.cyt.sys.service.BaseService;
import com.cyt.work.question.model.dto.QuestionUserDto;
import com.cyt.work.question.model.po.QuestionScore;
import com.cyt.work.question.model.vo.QuestionScoreVo;

import java.util.List;

/**
 * 问卷答题得分表
 *
 * @author congcong tao
 * @create 2019/7/8 10:44
 */
public interface IQuestionScoreService extends BaseService<QuestionScore> {

    /**
     * 分页查询
     * @param questionScoreVo
     * @param pageSize
     * @param pageNum
     * @author congcong tao
     * @date 2019/9/4 9:07
     */
    ReturnResult page(QuestionScoreVo questionScoreVo, int pageSize, int pageNum);

    /**
     * 保存得分
     * @param userId
     * @param scoreJson
     * @author congcong tao
     * @date 2019/7/11 9:12
     */
    ReturnResult saveQuestionScore(String userId, String scoreJson);

    /**
     * 查询考试人数
     * @param questionScore
     * @author congcong tao
     * @date 2019/8/21 15:45
     */
    long selectCountGroupByUser(QuestionScore questionScore);

    /**
     * 查询已答卷人员
     * @param questionId
     * @author congcong tao
     * @date 2019/9/2 16:46
     */
    List<QuestionUserDto> selectUserList(String questionId);

    List<QuestionScore> accept(QuestionScoreVo questionScoreVo);
}
